package com.cd.javacxy.module.web.service;

import com.cd.javacxy.common.model.entity.CxyAsk;
import com.cd.javacxy.common.model.query.AskQuery;
import com.cd.javacxy.common.utils.PageResult;
import com.cd.javacxy.exception.BussinessException;

import java.util.List;

/**
 * CxyAsk的服务接口
 *
 * @author yanghy
 */
public interface CxyAskService {
    PageResult<CxyAsk> findAskByPage(AskQuery askQuery);

    int findCount(AskQuery askQuery);

    void addAsk(CxyAsk ask) throws BussinessException;

    void setBestAnswer(Integer bestAnswerId, Integer askId, Integer userId) throws BussinessException;

    CxyAsk getAskById(Integer askId);

    CxyAsk showAsk(Integer askId) throws BussinessException;

    List<CxyAsk> findTopUsers();

    List<CxyAsk> findAskList();

    void deleteBatch(Integer[] ids) throws BussinessException;
}
